import {
	infoAPI,
	
} from '@/request/recharge/index.js';
// 获取用户信息（包含邀请码）
export let GetUserInvitationCode = async () => {
	let Info = await infoAPI();
	console.log(Info['data'],'Info')
	return Info['data'];
}
// 分享配文数据
export const consumerCard = async function() {
	let code = await GetUserInvitationCode();
	console.log(code)
	return {
		title: '我在白马晶选领到了消费补贴卡，话费充值和购物都补贴优惠了，真香，分享给你也点进来领一张！',
		path: `/sub_card/index/index?bm_yq_code=${code['userInfo']['invite_code']}`,
		imageUrl: 'https://img.agrimedia.cn/chwl/newsh.jpg'
	}
};

// 肯德基分享配文数据
export const KFCrestaurant = async function() {
	let code = await GetUserInvitationCode();
	console.log(code)
	return {
		title: '这里有一份超值肯德基补贴券，分享给你哦！生活好滋味，尽在肯德基。',
		path: `/pages/restaurant/index/index_kdj?bm_yq_code=${code['userInfo']['invite_code']}&brand_id=1&brand_name=肯德基`,
		imageUrl: 'https://img.agrimedia.cn/chwl/v2/KFC_share.jpg'
	}
};

// 瑞幸分享配文数据
export const RXrestaurant = async function() {
	let code = await GetUserInvitationCode();
	console.log(code)
	return {
		title: `美好时光，一起小蓝杯，一起瑞幸，点击这里，尽享5折哦`,
		path: `/pages/restaurant/index/index_rx?bm_yq_code=${code['userInfo']['invite_code']}&brand_id=13&brand_name=瑞幸`,
		imageUrl: 'https://img.agrimedia.cn/chwl/rx/RX_share.jpg'
	}
};

// 星巴克分享配文数据
export const XBKSharing = async function() {
	let code = await GetUserInvitationCode();
	console.log(code)
	return {
		title: '和你一起来享受星巴克时光 ，美好生活快来点这里有折扣哦',
		path: `/pages/restaurant/index/index_xbk?bm_yq_code=${code['userInfo']['invite_code']}&brand_id=10&brand_name=星巴克`,
		imageUrl: 'https://img.agrimedia.cn/chwl/xbk/xbk_sharing.jpg'
	}
}


// 团队分享配文数据
export const TeamSharing = async function() {
	let code = await GetUserInvitationCode();
	console.log(code)
	return {
		title: '我发现了一个超多折扣补贴的小程序，线上线下啥都有，快点开领取吧',
		path: `/pages/index/index?bm_yq_code=${code['userInfo']['invite_code']}`,
		imageUrl: 'https://img.agrimedia.cn/chwl/v2/Team_sharing.jpg'
	}
}

//转赠分享
export const subgiftSharing = async function(value) {
	console.log(value,"value")
	return {
		title: '好友喊你领取消费补贴啦',
		path: `/pages/pages-recharge/shareRedEnvelopes/index?code=${value}`,
		imageUrl: 'https://img.agrimedia.cn/chwl/newsh.jpg',
		desc:"消费补贴卡权益覆盖餐饮、话费、电商、影音娱乐、外卖打车等多种消费场景，消费补贴当钱花，快来领取吧！"
	}
}
